\ProvidesPackage{natim}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[french]{babel}
\usepackage{pifont}
\usepackage{placeins}
\usepackage{wrapfig}
\usepackage{listings}
\usepackage{graphicx}
\usepackage{shadow}
\usepackage{fancybox}
\usepackage{latexsym}
\usepackage{fullpage}
\usepackage{amssymb}
\usepackage{color}
\usepackage{calc}
\usepackage{footnote}
\usepackage{makeidx}
\usepackage[colorlinks=true]{hyperref}


\makesavenoteenv{tabular}

\setlength\parskip{1ex}

\newenvironment{intro}{\sffamily}{\newpage}

\newcommand{\image}[3]{
\begin{figure}[!htbp]
\centerline{\includegraphics[scale=#3]{images/#1}}
\caption{#2}
\label{#1}
\end{figure}
}

\newcommand{\encadre}[1]{
\vspace{2ex}
\shadowbox{\parbox{\textwidth-1cm}{\textsf{#1}}}
\vspace{2ex}
}

\definecolor{notebg}{rgb}{0.85,0.85,0.85}
\definecolor{noterulefg}{rgb}{0.45,0.45,0.45}
\newcommand{\notemarge}[1]{%
  \renewcommand{\baselinestretch}{0.7}%
  \marginpar{%
    \ifodd\value{page}%
    \hbox{%
      $\vartriangleleft$
      \vbox{%
        {\color{noterulefg}\hrule}%
        \hbox{%
          {\color{noterulefg}\vrule}%
          \colorbox{notebg}{%
            \parbox{0.98\marginparwidth-4\fboxsep-0.5cm}{\sffamily{\scriptsize{#1}}}%
          }%
        }%
      }
    }%
    \else%
    \hbox{%
      \vbox{%
        {\color{noterulefg}\hrule}%
        \hbox{%
          \colorbox{notebg}{%
            \parbox{0.98\marginparwidth-4\fboxsep-0.5cm}{\sffamily{\scriptsize{#1}}}%
          }%
          {\color{noterulefg}\vrule}%
        }%
      }
      $\vartriangleright$%
    }%
    \fi%
  }%
}

\newenvironment{code}
{\begin{lstlisting}[frame=leftline,breaklines=true]}
{\end{lstlisting}}
